package code.remote.request {

import code.vo.Topic;
import code.vo.User;


public class InsertVoteRequest extends AbstractActionRequest {
	
	private static const REQUEST_TYPE: String = "insert_vote";
	
	private var user: User;
	private var topic: Topic;
	
	public function InsertVoteRequest(user: User, topic: Topic) {
		super(REQUEST_TYPE);
		
		this.user = user;
		this.topic = topic;
	}
	
	protected final override function getXmlData(): String {
		return '<Request><Vote><UserId>' + this.user.userId + '</UserId><TopicId>' + this.topic.topicId + '</TopicId></Vote></Request>';
	}
	
}
}